<!--简易的echarts图展示-->
<script setup>
import * as echarts from 'echarts';
import useUserStore from '@/stores/user.js'
import UserApis from '@/apis/user.js'

const userStore = useUserStore()
const tableData=ref([])
// onMounted(() => {
//   myChart =echarts.init(document.getElementsByClassName('myChartContainer')[0]);
//   myChart.setOption(getOption());
// })


// 获取学情数据
function getUserStudyData() {
  UserApis.getUserStudyData(userStore.selectCategory.categoryId).then(res => {
    tableData.value=[res.data]
  })
}

function init() {
  getUserStudyData()
}

init()
</script>

<template>
  <div>
    <el-table :data="tableData">
      <el-table-column label="已做题数" prop="doCount">

      </el-table-column>
      <el-table-column label="成功率" prop="success">

      </el-table-column>
      <el-table-column label="排名" prop="rank">

      </el-table-column>
      <el-table-column label="总题数" prop="qCount">

      </el-table-column>
      <el-table-column label="收藏数" prop="cc">

      </el-table-column>
      <el-table-column label="错题数量" prop="ec">

      </el-table-column>
      <el-table-column label="笔记数量" prop="noteCount">

      </el-table-column>
    </el-table>
  </div>
</template>

<style scoped>

</style>